package com.ws.game.lesson3.fire
{
	import com.ws.game.common.components.SpriteLoader;
	import com.ws.game.skins.PlayerSkin;
	import com.ws.game.skins.MonsterSkin;
	
	import flash.events.Event;
	
	public class L3 extends SpriteLoader
	{
		public function L3()
		{
			super();
		}
		
		override protected function addGameObjects():void{		
			//player
			var gCtrl : KeyBoardCtrl=new KeyBoardCtrl();
			var gObj :Player =new Player(gCtrl,new PlayerSkin());
			this.gSce.addGameObject(gObj);
			
			//monster
			for (var i:uint = 0; i < 6; i++)
			{
				var ctrl2:MonsterCtrl = new MonsterCtrl();
				var monster:Monster = new Monster(ctrl2, new MonsterSkin());
				monster.x = int(Math.random() * 500);
				monster.y = int(Math.random() * 300);
				gSce.addGameObject(monster);
			}
		}
	}
}